﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using GolSig.Library;

namespace Test.GolSig.Library.GameSpecs
{
    /// <summary>
    /// Summary description for WhenInitializingGame
    /// </summary>
    [TestClass]
    public class WhenInitializingGame
    {
      

        [TestMethod]
        public void BoradShouldBeInitialized()
        {
            Game game = new Game(new BoardSize(10, 10));
            Position p55 = new Position ( 5,  5 );
            Position p56 = new Position ( 5,  6 );
            Position p46 = new Position ( 4,  6 );
            Position p67 = new Position ( 6, 7 );
            Position p78 = new Position ( 7, 8 );
            game.Initialize(new CellInfo[] { new CellInfo(  p55, true), new CellInfo(p56, true),new CellInfo(  p46, true),new CellInfo(  p67, true), new CellInfo(  p78, true) });
            Assert.IsTrue(game.Cell(p55).Alive);
            Assert.IsTrue(game.Cell(p56).Alive);
            Assert.IsTrue(game.Cell(p46).Alive);
            Assert.IsTrue(game.Cell(p67).Alive);
            Assert.IsTrue(game.Cell(p78).Alive);
        }
    }
}
